package admin.entity;

import admin.core.annotation.Query;
import admin.core.annotation.TableField;
import admin.core.annotation.TableId;
import admin.core.annotation.TableName;
import admin.core.enums.IdType;
import admin.core.enums.QueryType;

@TableName(label = "用户", value = "user")
public class User {
    @TableId(type = IdType.AUTO)
    @Query(QueryType.EQUALS)
    private Integer id;

    @TableField(label = "姓名")
    @Query(QueryType.LIKE)
    private String name;

    @TableField(label = "角色")
    private String role;

    public User() {
    }

    public User(Integer id, String name, String role) {
        this.id = id;
        this.name = name;
        this.role = role;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getRole() {
        return role;
    }

    public void setRole(String role) {
        this.role = role;
    }
}
